package gagnatech.impl;

import gagnatech.dao.MediathequeDAO;
import gagnatech.database.DatabaseDAO;
import gagnatech.entity.Mediatheque;

public class MediathequeDaoImpl implements MediathequeDAO {

	private DatabaseDAO dao;
	
	public MediathequeDaoImpl() {
		dao = new DatabaseDAO();
	}

	public boolean addMediatheque(Mediatheque mediatheque) {
		return dao.insert(mediatheque);
	}

	public Mediatheque getMediathequeById(int id) {
		System.out.println("*********************************************************");
		Mediatheque m = (Mediatheque)dao.select("Mediatheque", id);
		System.out.println("M : " + m);
		return m;
	}
}
